//
//  NSDate+Utility.h
//  MyLawyerFoundation
//
//  Created by Jinxiao on 6/30/15.
//
//

#import <Foundation/Foundation.h>

@interface NSDate (Utility)

- (BOOL)earlierThan:(NSDate *)date;
- (BOOL)laterThan:(NSDate *)date;
- (BOOL)sameDayAs:(NSDate *)date;
- (BOOL)sameYearAs:(NSDate *)date;
- (BOOL)sameWeekAs:(NSDate *)date;
- (BOOL)sameMonthAs:(NSDate *)date;

- (NSDate *)previousMonth;
- (NSDate *)nextMonth;

- (NSDate *)previousDay;
- (NSDate *)nextDay;

- (NSDate *)nextWeek;

- (NSDate *)dateAtStartOfWeek;
- (NSDate *)dateAtEndOfWeek;

- (NSDate *)dateAtStartOfDay;
- (NSDate *)dateAtEndOfDay;

- (NSDate *)dateAtStartOfMonth;
- (NSDate *)dateAtEndOfMonth;

- (NSDate *)dateAtStartOfYear;
- (NSDate *)dateAtEndOfYear;

- (NSString *)timeAgoForTimeline;

@end